import * as dev from './url.dev';
import * as build from './url.build';

var base ;
if (process.env.NODE_ENV === "production") {
  base = build; //生产
} else {
  base = dev; //开发
}

import system       from './children/system';
import panel       from './children/panel';
import graph       from './children/graph';

import datasource   from './children/datasource';

const LOGIN_URL = SYSTEM_MANAGE_VUE_CONFIG.apiServer.BASE_URL

export const API_LIST = {
    login: LOGIN_URL + '/authorize/login',
    userInfo: LOGIN_URL + '/system/users/info',

    ...system(base.SERVER_BAS_URL,base.SYSTEM_BAS_URL, base.GATEWAY_URL),

    ...panel(base.DATAVIEW_URL, base.SERVER_BAS_URL,base.KPIVIEW_URL),
    ...graph(base.SERVER_BAS_URL,base.SERVER_kPI_URL, base.SYSTEM_MOCK, base.UPLOAD_SERVER),
    ...datasource(base.SERVER_BAS_URL, base.SYSTEM_BAS_FILE_URL),
};

export const ZLST_WEB_LOCATION =base.CONFIG;
